#pragma once
/* Copyright (C) 2009 Vlad Roubtsov. All rights reserved. */

#include <iostream>
#include <string>

#include <boost/ptr_container/ptr_map.hpp>
using boost::ptr_map;

//----------------------------------------------------------------------------
namespace vr
{
namespace deject
{

typedef std::string component_id_type;

namespace dep_value_type { enum enum_t
{
    first = 0,

    REFERENCE,
    SEQ_OF_REFERENCE,
    VALUE,
    MAP_OF_VALUE,

    length
};

inline std::ostream &
operator<< (std::ostream & os, const enum_t & e)
{
    switch (e)
    {
#define __VR_CASE(x) case x:  return os << #x;

        __VR_CASE (REFERENCE)
        __VR_CASE (SEQ_OF_REFERENCE)
        __VR_CASE (VALUE)
        __VR_CASE (MAP_OF_VALUE)

#undef __VR_CASE

        default: return os; // TODO better handling (note: don't throw in case this is used inside an exception handler)

    } // end of switch
}
} // end of enum

} // end of 'container'
} // end of namespace
//----------------------------------------------------------------------------
